<%@ page language="java" import="java.util.*" pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    
    <title></title>
    <link rel="stylesheet" type="text/css" href="${path}/css/main.css">
	<link rel="stylesheet" type="text/css" href="${path}/css/mainTable.css">
	<script type="text/javascript" language="javascript" src="${path}/js/calendar/js/WdatePicker.js"></script>
	<script type="text/javascript" language="javascript" src="${path}/js/jquery.js"></script>
	<script type="text/javascript" language="javascript" src="${path}/js/jquery.blockUI.js"></script>
  </head>
  <body>
    <div>
    	<form id="provinceAnalysisPartnerForm" name="provinceAnalysisPartnerForm" method="post" action="">
    		<p>分省数据</p>
    		<table>
    			<thead>
    				<tr>
    					<th>省份</th>
    					<th>计费数量</th>
    					<th>同步数量</th>
    					<th>计费时长（分）</th>
    					<th>同步时长（分）</th>
    					<th>总收入（元）</th>
    					<th>同步收入（元）</th>
    				</tr>
    			</thead>
    			<c:choose>
    				<c:when test="${analysisVoList != null && fn:length(analysisVoList) > 0}">
    					<c:forEach var="analysisVo" items="${analysisVoList }" varStatus="list">
    						<tr style="${list.index%2 != 0 ? 'background-color: #fea;' : 'background-color: #fff;' }">
    							<td>${analysisVo.province }</td>
    							<td>${analysisVo.fee_user_num_sum }</td>
    							<td>${analysisVo.fee_user_num }</td>
    							<td>${analysisVo.fee_minute_sum }</td>
    							<td>${analysisVo.fee_minute }</td>
    							<td>${analysisVo.fee_price_sum }</td>
    							<td>${analysisVo.fee_price }</td>
    						</tr>
    						<c:set var="fee_user_num_sum_count" value="${fee_user_num_sum_count + analysisVo.fee_user_num_sum }"></c:set>
    						<c:set var="fee_user_num_count" value="${fee_user_num_count + analysisVo.fee_user_num  }"></c:set>
    						<c:set var="fee_minute_sum_count" value="${fee_minute_sum_count + analysisVo.fee_minute_sum }"></c:set>
    						<c:set var="fee_minute_count" value="${fee_minute_count + analysisVo.fee_minute }"></c:set>
    						<c:set var="fee_price_sum_count" value="${fee_price_sum_count + analysisVo.fee_price_sum }"></c:set>
    						<c:set var="fee_price_count" value="${fee_price_count + analysisVo.fee_price }"></c:set>
    						
    					</c:forEach>
    					<tr style="${fn:length(analysisVoList)%2 != 0 ? 'background-color: #fea;' : 'background-color: #fff;' }">
    						<td>总计</td>
    						<td>${fee_user_num_sum_count }</td>
    						<td>${fee_user_num_count }</td>
    						<td>${fee_minute_sum_count }</td>
    						<td>${fee_minute_count }</td>
    						<td>${fee_price_sum_count }</td>
    						<td>${fee_price_count }</td>
    					</tr>
    				</c:when>
    				<c:otherwise>
    					<tr>
    						<td>暂无分省数据</td>
    					</tr>
    				</c:otherwise>
    			</c:choose>
    		</table>
    	</form>
    </div>
  </body>
</html>